package com.baidu.springcloud.myhandler;

import com.alibaba.csp.sentinel.slots.block.BlockException;
import com.baidu.springcloud.common.CommonResult;

/**
 * @author ShiLei
 * @version v1.0
 * @date 2020-04-04 15:43
 * <p>
 * 自定义限流规则异常处理类
 */
public class ConsumerBlockHandler {

    public static CommonResult handlerException1(BlockException exception) {
        return new CommonResult(4444, "按客户自定义全局处理 handlerException1 ---- 1");
    }

    public static CommonResult handlerException2(BlockException exception) {
        return new CommonResult(4444, "按客户自定义全局处理 handlerException2 ---- 2");
    }
}
